package com.vpen.iot.controller;

import org.apache.poi.xssf.streaming.SXSSFWorkbook;
import org.apache.poi.xssf.usermodel.XSSFWorkbook;

import java.io.IOException;
import java.io.OutputStream;

/**
 * @author Vpen
 * @date 2024/8/15 17:37
 */
public class MySXSSFWorkbook extends SXSSFWorkbook {
    @Override
    public void write(OutputStream stream) throws IOException {
        XSSFWorkbook workbook = getXSSFWorkbook();
        flushSheets();
        workbook.write(stream);
    }
}
